package data.nanjing.expo.models.domain.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import data.nanjing.expo.common.DateTimeUtil;
import data.nanjing.expo.common.Util;
import data.nanjing.expo.models.domain.SysConfig;

import java.util.Date;
import java.util.List;

/**
 * Created by zjp on 2018/6/24.
 * QQ：34948062
 * github: https://www.github.com/zjp1029
 * web： http://www.zjp1029.cn
 */
public class ActivityInfoDto {

    private Integer id;

    private Integer userId; //发布者id

    private String activityContent; //活动内容

    private String activityName;    //活动名称

    private String province;    //省

    private String city;    //市

    private String area;    //区

    private String industry;    //行业

    private String refuseReason;    //违规原因

    private Integer status;     //活动状态，默认为normal，违规设置为refuse,取消为cancel

    private String fee; //是否免费

    private String imagePath;   //图片路径

    private Integer allowNum;    //限定活动人数

    private Integer applyNumber;

    private Integer favoriteNumber;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date startTime; //活动开始时间

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date endTime;   //活动结束时间

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date updateTime;


    private String activityGuide;   //参会指导

    private String street;  //街道地址

    private String introduce;   //介绍

    private String schedule;    //日程

    private String organizations;   //组织机构

    private String location;    //目的地

    private String guestInfo;   //嘉宾信息

    private List<SysConfig> tags;   //标签

    private String finalPath;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getActivityContent() {
        return activityContent;
    }

    public void setActivityContent(String activityContent) {
        this.activityContent = activityContent;
    }

    public String getActivityName() {
        return activityName;
    }

    public void setActivityName(String activityName) {
        this.activityName = activityName;
    }

    public String getProvince() {
        return province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    public String getCity() {
        return city;
    }

    public void setCity(String city) {
        this.city = city;
    }

    public String getArea() {
        return area;
    }

    public void setArea(String area) {
        this.area = area;
    }

    public String getIndustry() {
        return industry;
    }

    public void setIndustry(String industry) {
        this.industry = industry;
    }

    public String getRefuseReason() {
        return refuseReason;
    }

    public void setRefuseReason(String refuseReason) {
        this.refuseReason = refuseReason;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getFee() {
        return fee;
    }

    public void setFee(String fee) {
        this.fee = fee;
    }

    public String getImagePath() {
        return imagePath;
    }

    public void setImagePath(String imagePath) {
        this.imagePath = imagePath;
    }

    public Integer getAllowNum() {
        return allowNum;
    }

    public void setAllowNum(Integer allowNum) {
        this.allowNum = allowNum;
    }

    public String getStartTime() {
        return DateTimeUtil.dateFormat(startTime, DateTimeUtil.MINUTE_PATTERN);
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public String getEndTime() {
        return DateTimeUtil.dateFormat(endTime, DateTimeUtil.MINUTE_PATTERN);
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public String getCreateTime() {
        return DateTimeUtil.dateFormat(createTime, DateTimeUtil.MINUTE_PATTERN);
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getUpdateTime() {
        return DateTimeUtil.dateFormat(updateTime, DateTimeUtil.MINUTE_PATTERN);
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getActivityGuide() {
        return activityGuide;
    }

    public void setActivityGuide(String activityGuide) {
        this.activityGuide = activityGuide;
    }

    public String getStreet() {
        return street;
    }

    public void setStreet(String street) {
        this.street = street;
    }

    public String getIntroduce() {
        return introduce;
    }

    public void setIntroduce(String introduce) {
        this.introduce = introduce;
    }


    public String getSchedule() {
        return schedule;
    }

    public void setSchedule(String schedule) {
        this.schedule = schedule;
    }

    public String getOrganizations() {
        return organizations;
    }

    public void setOrganizations(String organizations) {
        this.organizations = organizations;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public String getGuestInfo() {
        return guestInfo;
    }

    public void setGuestInfo(String guestInfo) {
        this.guestInfo = guestInfo;
    }

    public Integer getApplyNumber() {
        return applyNumber;
    }

    public void setApplyNumber(Integer applyNumber) {
        this.applyNumber = applyNumber;
    }

    public Integer getFavoriteNumber() {
        return favoriteNumber;
    }

    public void setFavoriteNumber(Integer favoriteNumber) {
        this.favoriteNumber = favoriteNumber;
    }

    public void setTags(List<SysConfig> tags) {
        this.tags = tags;
    }

    public List<SysConfig> getTags() {
        return tags;
    }

    public String getFinalPath() {
        return Util.getFinalFilePath(imagePath, "480", "293");
    }

    @Override
    public String toString() {
        return "ActivityInfoDto{" +
                "id=" + id +
                ", userId=" + userId +
                ", activityContent='" + activityContent + '\'' +
                ", activityName='" + activityName + '\'' +
                ", province='" + province + '\'' +
                ", city='" + city + '\'' +
                ", area='" + area + '\'' +
                ", industry='" + industry + '\'' +
                ", refuseReason='" + refuseReason + '\'' +
                ", status=" + status +
                ", fee='" + fee + '\'' +
                ", imagePath='" + imagePath + '\'' +
                ", allowNum=" + allowNum +
                ", startTime=" + startTime +
                ", endTime=" + endTime +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                ", activityGuide='" + activityGuide + '\'' +
                ", street='" + street + '\'' +
                ", introduce='" + introduce + '\'' +
                ", tags='" + tags + '\'' +
                ", schedule='" + schedule + '\'' +
                ", organizations='" + organizations + '\'' +
                ", location='" + location + '\'' +
                ", guestInfo='" + guestInfo + '\'' +
                '}';
    }
}
